package com.pagepub.expo.services;

import java.util.HashMap;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;

import com.pagepub.expo.entity.CorpCommpany;
import com.pagepub.expo.manager.CorpCommpanyMng;

public class ServiceAPI {

	public String getUserName(String name) {
		
		return "HELLO "+name.toUpperCase()+"!";
	}
	
	
	   @Autowired
	   @Qualifier("corpCommpanyMng")
		private CorpCommpanyMng corpCommpanyMng;
	    
		public String hello(String name) {
			
			return "HELLO "+name.toUpperCase()+"!";
		}
		 
		
		public HashMap getCorpCommpanyByCorpId(String corpid){
			HashMap resultObj=new HashMap();
			//CorpCommpany corpCommpany=corpCommpanyMng.findByName(corpid);
			resultObj.put("nameSpace","com.flashseer.org");
			return resultObj;

			
		
		}
		
		public CorpCommpany getCorpCommpany(String corpid) {
			CorpCommpany corpCommpany=corpCommpanyMng.findByName(corpid);
			return corpCommpany;
		}
}
